package com.quanxiaoha.xiaohashu.auth.controller;

import java.time.LocalDateTime;

import com.quanxiaoha.framework.biz.operationlog.aspect.ApiOperationLog;
import com.quanxiaoha.framework.common.response.Response;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * description: 测试类
 * taskId：
 * <pre>
 * change history:
 * date             defect#             person                comments
 * ---------------------------------------------------------------------
 * 2025/2/22       ********         zhaochaoyue        create file
 * </pre>
 *
 * @author: zhaochaoyue
 * @date: 2025/2/22 23:48
 * @copyright: 2025
 */
@RestController
public class TestController {

    @GetMapping("/test")
    @ApiOperationLog(description = "测试接口")
    public Response<String> test() {
        return Response.success("Hello, 犬小哈专栏");
    }

    @GetMapping("/test2")
    @ApiOperationLog(description = "测试接口")
    public Response<User> test2() {
        return Response.success(User.builder()
            .nickName("犬小哈")
            .createTime(LocalDateTime.now())
            .build());
    }
}
